{% extends "base.html" %}
{% load static %}
{% block title %}
{{newName}}
<!--{% endblock %}-->
{% block content %}
<link href="{% static 'css/news.css' %}" rel="stylesheet">
<!-- 广告横幅 -->
<div class="container-fluid">
    <div class="row">
        <img class="img-responsive model-img" src="{% static 'img/new.jpg' %}">
    </div>
</div>
<!-- 主体内容 -->
<div class="container">
    <div class="row row-3">
        <div class="model-details-title">
            {{newName}}
            <div class="col-md-7 hidden-xs model-details-title-search">
                <form method="get" action="/search/">
                    {% csrf_token %}
                    <div class="input-group">
                        <input type="text" name="keyword" class="form-control" placeholder="请输入关键词" required />
                        <span class="input-group-btn">
                            <input type="submit" class="btn btn-default" value="查询" />
                        </span>
                    </div>
                </form>
            </div>
        </div>
        <div class="model-details">
            {% for mynew in newList %}
            <div class="news-model">
                <img src="{% static 'img/newsicon.gif' %}">
                <a href="{% url 'newsApp:newDetail' mynew.id %}"><b>{{mynew.title}}</b></a>
                <span>【{{mynew.publishDate|date:"Y-m-d"}}】</span>
            </div>
            {% endfor %}
        </div>
    </div>
</div>
{% endblock %}